package tests;

import tester.*;

@Example
public class Exceptions {

	public Exceptions(){}
	
	@TestMethod
	public void testExceptions(Tester t){
		int[] foo = new int[10];
		
		try{
			foo[10] = 5;
			t.fail("ArrayIndexOutOfBoundsException should have been thrown.");
			t.fail();
			t.checkExpect(1, 2);
		}catch(ArrayIndexOutOfBoundsException ex){
			t.success("ArrayIndexOutOfBoundsException was properly thrown.");
			t.success();
		}
	}
	
	public static void main(String[] args){
		Tester.runFullReport(new Exceptions());
	}
	
	
}
